﻿@{
    Layout = null;
}
<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="X-UA-Compatible" content="IE=7" />
    <title>BoardTop</title>
    @if (false)
    {
        <script src="../../Scripts/jquery-vsdoc.js" type="text/javascript"></script>
        <script src="../../Scripts/ASPxScriptIntelliSense.js" type="text/javascript"></script>
    }

    <script src="@Url.Content("~/Scripts/jquery.min.js", true)" type="text/javascript"></script>

    @Html.DevExpress().GetStyleSheets(

    new StyleSheet { ExtensionType = ExtensionType.ComboBox, Theme = DevExpressHelper.Theme }
    )
    @Html.DevExpress().GetScripts(
                new Script { ExtensionType = ExtensionType.ComboBox }
    )
    <style type="text/css">
        body
        {
            margin: 0px;
            font-size: 14px;
        }
    </style>

    <script>
        var GoUrlPrefix = "";

        function noneChooseYear() {
            $("#lblYear").css("display", "none");
            $("#chooseYear").css("display", "none");
        }
        /*显示年度选择框*/
        /*currentYear-当前年度 maxYear最大年度,minYear最小你那度,跳转url前缀*/
        function showChooseYear(currentYear, maxYear, minYear, urlPrefix) {
            $("#lblYear").css("display", "block");
            $("#chooseYear").css("display", "block");
            var clientchooseYearObj = ASPxClientSpinEdit.Cast("chooseYear");

            clientchooseYearObj.SetValue(currentYear);
            clientchooseYearObj.SetMaxValue(maxYear);
            clientchooseYearObj.SetMinValue(minYear);
            GoUrlPrefix = urlPrefix;

        }
        function goUrl() {
            var clientchooseYearObj = ASPxClientSpinEdit.Cast("chooseYear");
            var year = clientchooseYearObj.GetValue();
            parent.$("#contentframe").attr("src", GoUrlPrefix + year);
        }
    
    </script>

</head>
<body>
    <table width="100%" border="0" cellspacing="0" cellpadding="0" style="height: 24px;">
        <tr>
            <td  style="width:400px;background-image: url(@Url.Content("~/Content/images/boardtop_bg.jpg", true))" valign="middle">
                &nbsp;<img src="@Url.Content("~/Content/images/boardtop.gif", true)" />&nbsp;<span id="head_txt">我的桌面</span> </td>
            <td style="width:40px; background-image: url(@Url.Content("~/Content/images/boardtop_bg.jpg", true))" valign="middle" align="left">
                <span style="display: none" id="lblYear">年度:</span></td>
            <td style="background-image: url(@Url.Content("~/Content/images/boardtop_bg.jpg", true))" valign="middle" align="left">
                @Html.DevExpress().SpinEdit(
                        settings =>
                        {
                            settings.Name = "chooseYear";
                            settings.Width = 100;
                            settings.ClientVisible = false;
                            settings.Properties.AllowMouseWheel = false;
                            settings.Properties.ClientSideEvents.NumberChanged = "function(s,e){goUrl()}";
                        }).GetHtml()</td>
        </tr>
    </table>
</body>
</html>
